﻿using System;
using System.Collections.Generic;
using System.Web;
using Rabbit.Logic;
using RabbitManage.Code;

namespace RabbitManage.UI
{
    public partial class DiscountStrategy : System.Web.UI.Page
    {
        protected List<Discount> list;

        protected void Page_Load(object sender, EventArgs e)
        {
            HttpCookie cookie = Request.Cookies[Constant.CookieName];
            string shopId = cookie.Values[Constant.CookieUid];
            Shop shop = RabbitUse.GetShopByShopId(Db.Store, shopId);
            list = shop.Discounts;

            myRepeater.DataSource = list;
            myRepeater.DataBind();
        }
    }
}